home *** CD-ROM | disk | FTP | other *** search
/ Meeting Pearls 1 / Meeting Pearls Vol 1 (1994).iso / installed_progs / gfx / lise2.1 / lise / src / hco.c < prev    next >
Encoding:
C/C++ Source or Header  |  1993-04-15  |  1.6 KB  |  73 lines

  1. #include <stdio.h>
  2. #ifdef AMIGA
  3. #include <gfxamiga.h>
  4. #else
  5. #include <gfx.h>
  6. #endif
  7.  
  8. help()
  9. {
  10. printf("hco [-out drivername] [-iff filename] [-hpgl filename] [-ps filename]\n");
  11. printf("make hardcopy of LISE picture\n");
  12. printf("options:\n");
  13. printf("   -out  string       sets another printer driver\n");
  14. printf("   -iff  filename     print Amiga IFF (bitmap) output to file\n");
  15. printf("   -hpgl filename     print HP-GL output to file\n");
  16. printf("   -ps   filename     print PostScript output to file\n");
  17. printf("   -dxf  filename     print DXF (exchangable CAD format) to file\n");
  18. printf("   -adraw filename    print Aegis Draw (Amiga CAD Format) to file\n");
  19. printf("   -bold              make all lines twice as thick\n");
  20. }
  21.  
  22. main(argc,argv)
  23. int argc;
  24. char *argv[];
  25. {
  26. int n,m,i;
  27. char s[80],z[80];
  28. float a;
  29.  
  30.  
  31.    n = 0;
  32.    if(checkopt(argc,argv,"-bold",s)) n = 128;
  33.  
  34.    strcpy(s,"");
  35.    if(checkopt(argc,argv,"-out",s)) strcpy(s,z);
  36.  
  37.    tekopen();
  38.  
  39.    if(checkopt(argc,argv,"-iff",s)) {
  40.       sprintf(z,"%d %s",4 + n,s); special_gfx(z);
  41.       close(_tek4014);
  42.       exit(0);
  43.    }
  44.  
  45.    if(checkopt(argc,argv,"-hpgl",s)) {
  46.       sprintf(z,"2 %s",s); special_gfx(z);
  47.       close(_tek4014);
  48.       exit(0);
  49.    }
  50.  
  51.    if(checkopt(argc,argv,"-dxf",s)) {
  52.       sprintf(z,"6 %s",s); special_gfx(z);
  53.       close(_tek4014);
  54.       exit(0);
  55.    }
  56.  
  57.    if(checkopt(argc,argv,"-adraw",s)) {
  58.       sprintf(z,"5 %s",s); special_gfx(z);
  59.       close(_tek4014);
  60.       exit(0);
  61.    }
  62.  
  63.    if(checkopt(argc,argv,"-ps",s)) {
  64.       sprintf(z,"3 %s",s); special_gfx(z);
  65.       close(_tek4014);
  66.       exit(0);
  67.    }
  68.  
  69.    sprintf(z,"%d %s",1 + n,s); special_gfx(z);
  70.    close(_tek4014);
  71.    exit(0);
  72. }
  73.